import request from '@/utils/request'

export const getResourcePages = data => {
  return request({
    method: 'POST',
    url: `/boss/resource/getResourcePages`,
    data,
  })
}

export const saveOrUpdate = data => {
  return request({
    method: 'POST',
    url: `/boss/resource/saveOrUpdate`,
    data,
  })
}

export const deleteResource = id => {
  return request({
    method: 'DELETE',
    url: `/boss/resource/${id}`,
  })
}

export const getAllResourceCategories = () => {
  return request({
    method: 'GET',
    url: `/boss/resource/category/getAll`,
  })
}
